#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>

int Fun(int n, int k)
{
	if (k == 1)
		return n;
	else
		return n * Fun(n, k - 1);
}

int main()
{
	int n = 0;
	int k = 0;
	scanf("%d %d", &n, &k);
	printf("%d\n", Fun(n, k));
	return 0;
}
